Adel Gadllah [Sun, 17 Feb 2013 19:45:14 +0000 (20:45 +0100)]
Fix XDND regression
The top_window_group blocks the panel elements from being found by the XDND
pick so hide the whole group from picks as we never attempt to pick its contents
anyway.
Cosimo Cecchi [Sat, 16 Feb 2013 20:36:57 +0000 (15:36 -0500)]
overviewControls: account for the search entry in each control
Account for the search entry space at the bottom (the former message
tray clone) individually in each side control, instead of packing
another actor in the overview.
This allows us to extend the central view all the way to the bottom,
while still keeping controls centered vertically.
Cosimo Cecchi [Sat, 16 Feb 2013 20:34:33 +0000 (15:34 -0500)]
messageTray: remove overview special handling
Don't show the message tray in the overview by default. From now on the
message tray in overview behaves as regularly, i.e. it will slide up the
overview on Super+M keypress.
ScreenShield: don't add the source actor directly to the boxlayout
StBoxLayout always fills on the orthogonal direction, so the icon
becomes distorted as the layout grows to accomodate more details.
Instead, use a bin that aligns at the start.
MessageTray: don't clear the banner text when adding to the body
ScreenShield uses Notification.bannerBodyText to fill the body of detailed
notifications, so use a separate boolean property to indicate it was already
added to the body.
grabHelper: Ignore key focus changes when ungrabbing
Calling onUngrab() may change key focus, either directly or
indirectly (e.g. hiding the actor). Such key focus changes
would cause an extra actor to be ungrabbed, so make sure to
ignore such focus changes while we're ungrabbing.
grabHelper: Track the grab before trying to set key focus
If we don't this for a nested grabFocus grab, the notify::key-focus
will be called, not think that the new key focus is part of the
grab, and cancel the full grab. This leaves the grab helper in an
inconsistent and confused state, as the grab is pushed onto the
grab stack after.
While debugging, I found that the signal to focus-window-changed
was never getting disconnected, making a call to ungrab every time
the focus window changed, even if there were no focus grabs anymore.
shell-app-system: Ensure that we correctly order subsearches
As we use g_slist_prepend for efficiency when building the list
of results before ordering it, we need to make sure we traverse
the list of previous results backwards so that it's built in
the same order.
Cosimo Cecchi [Sat, 16 Feb 2013 17:55:59 +0000 (12:55 -0500)]
viewSelector: block show apps button checked signal when resetting state
When we reset the state of the checked button due to the overview
showing and hiding, block the normal checked callback and immediately
switch to the workspaces page, so that windows seamlessly fade in.
Cosimo Cecchi [Sat, 16 Feb 2013 17:50:25 +0000 (12:50 -0500)]
viewSelector: don't use resetShowAppsButton when pressing escape
Set the checked property explicitly. This is because
resetShowAppsButton() will only be used to flip the button state
blocking the page change in a future commit.
Cosimo Cecchi [Sat, 16 Feb 2013 17:45:10 +0000 (12:45 -0500)]
overview: change _hideInProgress to visibleTarget
And use it in overviewControls. When we moved this code from overview.js
to overviewControls.js we lost a condition so we now slide in controls
even when going back from the overview, which looks bad.
search: Simplify and correct behavior for substring searches
Early on, search was based on a list of terms, which was like a set
of tags, in that terms were OR'd, and that order didn't matter. As
such, modifying any one of the terms wouldn't produce new results.
Nowadays, providers take the order into account, so a substring
should only be the case if new terms are added to the end.
If WindowOverlay.relayout() is called without animation, we must stop
any preexisting animation, otherwise it will continue to run with the
previous parameters and cause the overlay to end up in the wrong position.
Cosimo Cecchi [Sat, 16 Feb 2013 01:50:26 +0000 (20:50 -0500)]
overviewControls: use translations for explicit slide in/out
The slideX property controls the allocation of the view selector; since
we now know when there are no visible views from the page-empty signal,
we can use it to set the full slideX for the next page at that time,
allowing the new view to fade in with the right width.
This allows us to use simple x translations for the side components when
switching pages, keeping the noise due to resizes at the minimum.
The slideX resize for now is kept for DnD, and will always be needed for
the thumbnails box when showing the windows page.
GdkPixbuf is stored in memory as individual bytes, in strict red-green-blue-alpha
order, while cairo image surfaces are stored as 32bits units whose
order depends on the endianess.
It is probably possible to do something better, taking advantage
of cogl and the GL using the actual component order, but for now
it is easier to use the GDK utility to convert the cairo surface.
If we increment our index variable while looping, this means that
firstNewEvent will be one higher than it should. With a length 1
array, all events will be removed, so this has a cascading effect
that events will not be stored at all.
NetworkMenu: use async initialization for libnm-glib objects
NMClient recently got more heavyweight, with a property holding supported
connections. As fully initializing a NMObject is a recursive operation
and requires multiple DBus calls, switch to async initalization for NMClient
and NMRemoteSettings.
Cosimo Cecchi [Sat, 26 Jan 2013 08:01:41 +0000 (03:01 -0500)]
endSessionDialog: don't use Tweener for the timer
We want to make Tweener short-circuit animations when resources are
constrained, so this is not going to work.
Instead, use a one-second timeout until the seconds left reach zero.
Rui Matos [Tue, 22 Jan 2013 00:46:48 +0000 (01:46 +0100)]
ibusCandidatePopup: Fix cursor positioning
After moving the dummy source actor, we still have to poke the
boxpointer so that it gets repositioned.
This has always been broken but went unnoticed until now since none of
the commonly used engines currently depend on this method. Thanks to
Mathieu Bridon for pointing it out.
Rui Matos [Thu, 14 Feb 2013 22:37:35 +0000 (23:37 +0100)]
CandidateArea: make setOrientation() public
setCandidates() has too many arguments and setting the orientation
isn't particularly related with it. It might also be useful to switch
orientation without changing the candidates.
Rui Matos [Wed, 2 Jan 2013 13:24:37 +0000 (13:24 +0000)]
ibusCandidatePopup: Style updates according to design mockups
Make it look more like the mockups.
In order to do that we stop using PopupMenu and friends as it doesn't
really buy us anything and just makes it more cumbersome to add the
style classes we need.
Cosimo Cecchi [Thu, 14 Feb 2013 19:41:38 +0000 (14:41 -0500)]
Introduce a SlideLayout layout manager
SlideLayout is a fixed layout that takes care of requesting and
allocating the right sizes so its contents can slide horizontally as the
actor is resized.
Sliding is controlled with a slideX and slideDirection properties, which
do the right thing wrt. RTL automatically.
Also add a SlidingControl base class that will be used by the overview
to pack and slide the workspace thumbnail switcher and the dash.
ShellSearchProvider: Update documentation about 'name' and 'id'
Document and enforce that a meta ID corresponds to the result ID
that we've passed in. This does not break any existing search providers
as far as I'm aware.
st-texture-cache: Use async variants of the icon loading API
While we were relying on gtk_icon_info_load_icon and friends being
thread-safe, there was no such guarantee, and recent caching that
was added to GTK+ made it non-threadsafe. To replace it, _async()
variants of the icon loading code were added that are thread-safe.
Use those instead of using our own worker threads.
This is nothing but a middle man, as the view selector already owns
the search system. We want to start being a bit more tricky with what
we do with the search system so that we ignore whitespace, so let's
cut the middle-man out now.
Have two branches, one for input region and one for struts. This
makes it easier to skip one of the branches, like in the case where
we want to skip input regions if we have a popup menu visible.
reparent() defines the new actor stacking order based on the
existing depth of the actor, which is flat out wrong. Simply
remove the actor from its old parent and add the new one in.
Adel Gadllah [Thu, 14 Feb 2013 17:22:24 +0000 (18:22 +0100)]
screenshot: Write metadata to png file
Use GdkPixbuf rather then cairo_surface_write_to_png_stream when saving
screenshots because this allows us to embedded metadata into the file which
is used by the background control panel to filter out screenshots.
Florian Müllner [Sat, 9 Feb 2013 22:05:43 +0000 (23:05 +0100)]
grabHelper: Restore the actually saved focus on ungrab
GrabHelper saves the actor that had key focus when taking over the grab
(if any). On ungrab, the key focus is either restored or moved to some
child of the saved actor. The latter is unexpected and causes some odd
behavior, so don't be fancy and only restore the actual focus.
NotificationDaemon: support sound in notifications
The notifications spec has two hints for playing a sound, sound-file
and sound-name. We can support them using the existing code that
wraps libcanberra.
Message tray and on-screen keyboard are now exclusive, so remove
all code that shuffles boxes around to make it possible to show
both at the same time.
Florian Müllner [Tue, 12 Feb 2013 19:56:24 +0000 (20:56 +0100)]
messageTray: Always hide while the OSK is up
The message tray currently operates in three modes: in the overview,
normal, and while the on-screen keyboard is up. The last case is
particularly odd, and exclusively used for chat-notifications. As
users can still use the Chat application directly on touch-only
devices, the additional mode isn't really justified, so remove it.
ScreenShield: try harder to become modal, and catch failures
The screenshield was not checking the return value of pushModal(), meaning
that it believed it was fully locked when it was not. Later, calling
popModal() would fail, causing an exception and blocking the unlock.
Now when we fail we include an explanatory message, pointing the user
to the actual cause of the issue.
ScreenShield: use a longer animation when locking manually
The curtain animation looks jerky at its current speed, and more so if
we blank the screen immediately at the end. Make it a little slower and
it becomes more confortable.